//
// Created by miaomiaole on 2024/1/22.
//

#ifndef OPENCV_INIT_SRC_IMGS_GRAY_H
#define OPENCV_INIT_SRC_IMGS_GRAY_H

#include <opencv2\opencv.hpp>
#include <iostream>
#include <opencv2\imgproc\types_c.h> //for CV_RGB2GRAY
#include <opencv2/core.hpp>
#include <opencv2/highgui.hpp>
#include <opencv2/imgproc.hpp>

using namespace cv;

using namespace std;

void rgb2_gray();

void gray_exp_imgs(Mat &input, Mat &output);

// 线性转换
Mat linearTransform(Mat srcImage, float a = 1.1, int b = 25);

Mat dividedLinerStreangth(Mat &input, float fStart = 1, float fEnd = 100, float fSout = 2, float fEout = 12);


Mat linerStream(Mat &input, float alpha = 2.0, float beta = 0);

// 对数转换
Mat log_transform(Mat srcImage, int c);


/**
 *
 * @param data:像素集合
 * @param grayscale:目标灰度级
 * @param rows
 * @param cols
 * @param type
 * @return
 */
Mat Normalize(vector<double> data, int grayscale, int rows, int cols, int type);


Mat NegativeLogTransform(Mat src, double parameter);


void conver_image();

#endif //OPENCV_INIT_SRC_IMGS_GRAY_H
